//
//  WFAddCropViewController.m
//  WisdomFarm
//
//  Created by sky on 2017/12/11.
//  Copyright © 2017年 sky. All rights reserved.
//

#import "WFAddCropViewController.h"

@interface WFAddCropViewController ()

@end

@implementation WFAddCropViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.url = [NSURL URLWithString:@"http://www.zjmb.gov.cn/zhnyqx/secondLevelPages/bindcrop.html"];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

- (void)selectCropCallback:(NSString *)cropJsonStr {
    WFFarmCrop *crop = [WFFarmCrop yy_modelWithJSON:cropJsonStr];
    mz_dispatch_on_main_queue(^{
        if (self.addCropFinish) {
            self.addCropFinish(crop);
        }
    });
}

@end
